package me.ingxin.android.router.base

import android.app.Application
import android.content.res.AssetManager
import android.content.res.Resources

/**
 * Created by ingxin on 2022/10/11
 * application component
 */
abstract class ApplicationComponent : BaseComponent() {

    /**
     * [Application.getResources]
     * @param applicationResources [Application.getResources]方法返回的值
     *  application.java
     * ```
     * override fun getResources(): Resources? {
     *    val applicationResources = super.getResources()
     *}
     * ```
     */
    open fun getResources(applicationResources: Resources?): Resources? {
        return applicationResources
    }

    /**
     * [Application.getAssets]
     * @param applicationAssetManager [Application.getAssets]方法返回的值
     *  application.java
     * ```
     * override fun getAssets(): AssetManager? {
     *    val applicationAssetManager = super.getAssets()
     *}
     * ```
     */
    open fun getAssets(applicationAssetManager: AssetManager?): AssetManager? {
        return applicationAssetManager
    }

}